package ${(introspectedTable.tableConfiguration.properties.fileDirectoryDTO)?substring(((introspectedTable.tableConfiguration.properties.fileDirectoryDTO)?index_of("/src/main/java/")+15))?replace("/",".")};

<#assign hasPrimaryKey=false/><#--表是否有主键-->
<#if introspectedTable.primaryKeyColumns ?size &gt;0 >
    <#assign hasPrimaryKey=true/>
</#if>
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;
import lombok.experimental.SuperBuilder;
import lombok.extern.slf4j.Slf4j;

<#-- 导入包，去除重复包 -->
<#assign ignoreFields=",createTime,updateTime,creator,updater,deleted,"/>
<#list introspectedTable.allColumns as allColumns>
    <#assign paramType=allColumns.fullyQualifiedJavaType.fullyQualifiedNameWithoutTypeParameters /><#--定义局部变量-->
    <#if paramType ?index_of("java.lang")==-1 && paramType ?index_of("[]")==-1><#--java.lang的包不需要导入，数组也不要导入，比如byte[] -->
        <#list introspectedTable.allColumns as allColumns2>
            <#if allColumns2.fullyQualifiedJavaType.fullyQualifiedNameWithoutTypeParameters ?index_of("java.lang")!=0>
                <#if allColumns.fullyQualifiedJavaType.fullyQualifiedNameWithoutTypeParameters ==allColumns2.fullyQualifiedJavaType.fullyQualifiedNameWithoutTypeParameters>
                    <#if allColumns_index==allColumns2_index>
                        <#if ignoreFields?index_of(allColumns.javaProperty)==-1>
                        <#-- 导入包名 -->
                            import ${allColumns.fullyQualifiedJavaType.fullyQualifiedNameWithoutTypeParameters};
                        </#if>
                    <#else>
                        <#break >
                    </#if>
                </#if>
            </#if>
        </#list>
    </#if>
</#list>


/***
* ---------------------------
* @Description:
* 表备注：${introspectedTable.remarks!}<#--deal null-->
* 数据库：${introspectedTable.tableConfiguration.schema!}
* 表名：${introspectedTable.fullyQualifiedTable.introspectedTableName}
* ---------------------------
* @author: ${introspectedTable.tableConfiguration.properties.auther!}
* @date: ${introspectedTable.tableConfiguration.properties.createTime!}
* @version: v1.0
* ---------------------------
*/
@Data
@Accessors(chain = true)
@NoArgsConstructor
@SuperBuilder(toBuilder=true)
@Slf4j
@Schema(description = "${introspectedTable.remarks!}")
public class ${className}DTO {

//↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓  start ↓↓↓↓↓↓↓↓↓↓↓↓↓↓↓

<#assign ignoreFields=",createTime,updateTime,creator,updater,deleted,"/>
<#if introspectedTable.fullyQualifiedTable.introspectedTableName =="stlmt_checking_pool">
    <#assign ignoreFields=""/>
</#if>
<#-- ----------  BEGIN 字段循环遍历  ---------->
<#-- 主键字段属性 -->
<#list introspectedTable.primaryKeyColumns as primaryKey>
    @Schema(description = "${primaryKey.remarks!}")
    private ${primaryKey.fullyQualifiedJavaType.shortNameWithoutTypeArguments} ${primaryKey.javaProperty};

</#list>

<#-- 非主键字段属性 -->
<#list introspectedTable.nonPrimaryKeyColumns as baseColumns>
    <#if ignoreFields?index_of(baseColumns.javaProperty)==-1>
    @Schema(description = "${baseColumns.remarks!?replace("\"","'")?replace("\n"," ")}")
    <#--这里仅暂时兼容不符合规范的字段，（以下划线结尾的） ............. start.-->
        <#if baseColumns.actualColumnName?length-1==baseColumns.actualColumnName?last_index_of("_")>
    <#--这里仅暂时兼容不符合规范的字段，（以下划线结尾的），处理：结尾加下划线-->
    private ${baseColumns.fullyQualifiedJavaType.shortNameWithoutTypeArguments} ${baseColumns.javaProperty}_;
        <#else>
    private ${baseColumns.fullyQualifiedJavaType.shortNameWithoutTypeArguments} ${baseColumns.javaProperty};
        </#if>
    <#--这里仅暂时兼容不符合规范的字段，（以下划线结尾的） ............. end.-->

    </#if>
</#list>
<#if introspectedTable.fullyQualifiedTable.introspectedTableName =="stlmt_checking_pool">
    @Schema(description = "创建人")
    private String creator;

    @Schema(description = "创建时间")
    private LocalDateTime createTime;
</#if>

//原始DTO类请勿添加非表中的字段，如果需要添加请另行创建DTO，确保所有字段在查询出来后均有值。
    //↑↑↑↑↑↑↑↑↑↑↑↑↑↑  end ↑↑↑↑↑↑↑↑↑↑↑↑↑↑

}
